﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace Toenda.Foundation.Audio {
	public class ID3v1Genre {
		/// <summary>
		/// Gets the name of the genre.
		/// </summary>
		/// <param name="langCode">The lang code.</param>
		/// <param name="genreId">The genre id.</param>
		/// <returns></returns>
		public static string GetGenreName(string langCode, int genreId) {
			return _Init(langCode)[genreId];
		}

		/// <summary>
		/// Inits the specified lang code.
		/// </summary>
		/// <param name="langCode">The lang code.</param>
		/// <returns></returns>
		private static Dictionary<int, string>  _Init(string langCode) {
			Dictionary<int, string> list = new Dictionary<int, string>();

			switch(langCode) {
				default:
				case "de":
					list.Clear();
					list.Add(0, "Blues");
					list.Add(01, "Classic Rock");
					list.Add(02, "Country");
					list.Add(03, "Dance");
					list.Add(04, "Disco");
					list.Add(05, "Funk");
					list.Add(06, "Grunge");
					list.Add(07, "Hip-Hop");
					list.Add(08, "Jazz");
					list.Add(09, "Metal");
					list.Add(10, "New Age");
					list.Add(11, "Oldie");
					list.Add(12, "Other");
					list.Add(13, "Popmusik");
					list.Add(14, "R&B");
					list.Add(15, "Rap");
					list.Add(16, "Reggae");
					list.Add(17, "Rock");
					list.Add(18, "Techno");
					list.Add(19, "Industrial");
					list.Add(20, "Alternative");
					list.Add(21, "Ska");
					list.Add(22, "Death Metal");
					list.Add(23, "Streich");
					list.Add(24, "Soundtrack");
					list.Add(25, "Euro-Techno");
					list.Add(26, "Ambient");
					list.Add(27, "Trip-Hop");
					list.Add(28, "Vocal");
					list.Add(29, "Jazz & Funk");
					list.Add(30, "Fusion");
					list.Add(31, "Trance");
					list.Add(32, "Klassische Musik");
					list.Add(33, "Instrumentalstück");
					list.Add(34, "Acid");
					list.Add(35, "House");
					list.Add(36, "Game");
					list.Add(37, "Sound Clip");
					list.Add(38, "Gospel");
					list.Add(39, "Noise");
					list.Add(40, "Alternative Rock");
					list.Add(41, "Bass");
					list.Add(42, "Soul");
					list.Add(43, "Punk");
					list.Add(44, "Space");
					list.Add(45, "Meditative");
					list.Add(46, "Instrumental Pop");
					list.Add(47, "Instrumental Rock");
					list.Add(48, "Ethnic");
					list.Add(49, "Gothic Rock");
					list.Add(50, "Dark Wave");
					list.Add(51, "Techno-Industrial");
					list.Add(52, "Electronic");
					list.Add(53, "Pop-Folk");
					list.Add(54, "Eurodance");
					list.Add(55, "Dream");
					list.Add(56, "Southern Rock");
					list.Add(57, "Comedy");
					list.Add(58, "Cult");
					list.Add(59, "Gangsta Rap");
					list.Add(60, "Top 40");
					list.Add(61, "Christlicher Rap");
					list.Add(62, "Pop / Funk");
					list.Add(63, "Jungle");
					list.Add(64, "Native US");
					list.Add(65, "Kabarett");
					list.Add(66, "New Wave");
					list.Add(67, "Psychedelic");
					list.Add(68, "Rave");
					list.Add(69, "Showtunes");
					list.Add(70, "Trailer");
					list.Add(71, "Lo-Fi");
					list.Add(72, "Tribal");
					list.Add(73, "Acid Punk");
					list.Add(74, "Acid Jazz");
					list.Add(75, "Polka");
					list.Add(76, "Retro");
					list.Add(77, "Musical");
					list.Add(78, "Rock 'n' Roll");
					list.Add(79, "Hard Rock");
					list.Add(80, "Folk");
					list.Add(81, "Folk-Rock");
					list.Add(82, "National Folk");
					list.Add(83, "Swing");
					list.Add(84, "Fast Fusion");
					list.Add(85, "Bebop");
					list.Add(86, "Latin");
					list.Add(87, "Revival");
					list.Add(88, "Keltische Musik");
					list.Add(89, "Bluegrass");
					list.Add(90, "Avantgarde");
					list.Add(91, "Gothic Rock");
					list.Add(92, "Progressive Rock");
					list.Add(93, "Psychedelic Rock");
					list.Add(94, "Symphonic Rock");
					list.Add(95, "Slow Rock");
					list.Add(96, "Big Band");
					list.Add(97, "Chorus");
					list.Add(98, "Easy Listening");
					list.Add(99, "Acoustic");
					list.Add(100, "Humour");
					list.Add(101, "Sprache");
					list.Add(102, "Chanson");
					list.Add(103, "Oper");
					list.Add(104, "Kammermusik");
					list.Add(105, "Sonate");
					list.Add(106, "Sinfonie");
					list.Add(107, "Booty Bass");
					list.Add(108, "Primus");
					list.Add(109, "Porn Groove");
					list.Add(110, "Satire");
					list.Add(111, "Slow Jam");
					list.Add(112, "Klub");
					list.Add(113, "Tango");
					list.Add(114, "Samba");
					list.Add(115, "Folklore");
					list.Add(116, "Ballade");
					list.Add(117, "Power Ballad");
					list.Add(118, "Rhytmic Soul");
					list.Add(119, "Freestyle");
					list.Add(120, "Duett");
					list.Add(121, "Punk-Rock");
					list.Add(122, "Drum Solo");
					list.Add(123, "A Cappella");
					list.Add(124, "Euro-House");
					list.Add(125, "Dance Hall");
					list.Add(126, "Goa");
					list.Add(127, "Drum ’n’ Bass");
					list.Add(128, "Club-House");
					list.Add(129, "Hardcore");
					list.Add(130, "Terror");
					list.Add(131, "Indie");
					list.Add(132, "BritPop");
					list.Add(133, "Negerpunk");
					list.Add(134, "Polsk Punk");
					list.Add(135, "Beatmusik");
					list.Add(136, "Christlicher Gangsta Rap");
					list.Add(137, "Heavy Metal");
					list.Add(138, "Black Metal");
					list.Add(139, "Crossover");
					list.Add(140, "Contemporary Christian");
					list.Add(141, "Christlicher Rock");
					list.Add(142, "Merengue");
					list.Add(143, "Salsa");
					list.Add(144, "Thrash Metal");
					list.Add(145, "Anime");
					list.Add(146, "JPop");
					list.Add(147, "Synthie Pop");
					break;
			}

			return list;
		}
	}
}
